/* *  
 * Copyright (C) 2004-2008 Mocha Almond Fudge AI, SIT KMUTT
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 2
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 */
package jboard.util;

import org.apache.log4j.Layout;
import org.apache.log4j.spi.LoggingEvent;

/**
 * Layout for logger class
 * 
 * @author -NOP-
 */
public class ModifyLog4JLayout extends Layout {
	StringBuffer sbuf = new StringBuffer(128);
	
	public ModifyLog4JLayout() {
	}
	
	public String format(LoggingEvent event) {
		sbuf.setLength(0);
		sbuf.append(event.getRenderedMessage());
		sbuf.append(LINE_SEP);
	    return sbuf.toString();
	}

	public boolean ignoresThrowable() {
		return true;
	}

	public void activateOptions() {
	}

}
